Vielleicht als erstes das Sprachproblem. Ich weiß nicht, die Vorlesung dieses Semesters ist auf in German or in English? In English, okay. I'll try my best.
My name is Frank Bauer, I'm from the Visual Computing Chair and Professor Stamminger asked me to take this lecture, not take it, hold this lecture, read this lecture about the Unity game engine and some things, some easy things you can do with them.
There will be an exercise, especially for the Unity in a small project, so this is a hands-on approach to this topic.
Everything you need to know for Unity, it's basically what you've learned in computer graphics, except that you don't have to program it yourself. It's there in a ready-made game engine and we will explore what you can do with it.
We're using Unity instead of Unreal Engine because it offers us more flexibility, because we'd like to be able to easily extend the engine without recompiling everything.
That's basically the general approach with the Unreal Engine. If you need to change something, it's an alternative game engine, you have to compile it yourself and that includes the complete engine source code.
This is a great opportunity because you can have a look at a real-world source code from a AAA game engine. Unreal, everything is free. You can have a look at everything they do.
You can check out how they do it, how they get their performance, what shaders they're writing. Everything is there, but this is a disadvantage as well because you have to recompile everything if you need to add a new shader pipeline or something.
Unity takes another approach. Its background is not AAA titles. It's more from the indie scene of development with a special focus on an easy-to-use editor from the start-up. They're catching up to the Unreal Engine when graphics is concerned.
They did a lot of work the last two years and they're almost there with the same graphics they can do, but they still kept the original premise that you can extend everything.
You can write complete shader pipelines without touching the source code of the game engine itself. You extend it with a scripting language.
Actually, it's not a scripting language. It's C Sharp and Mono, which is not scripting, but real programming, a real language that can be translated.
So this is the language you have to write in that case. It's C Sharp based. If you're extending Unity, you can use JavaScript as well. I didn't check that out. I don't know what the support level is.
I think they will drop JavaScript in a few years, months, days. I don't know. It's there from the beginning.
And there are other game engines as well. There's Go.Dot, another great open source game engine, actually with a good editor. They're using a scripting language, which borrows heavily from Python with syntax and elements. So that might be an easier start in this way.
And they're taking the same approach that the editor has to be easy to use for everyone that is starting.
So this is Unity Hub. Unity is free. Well, it's free for your personal projects. It's not free if you want to make money from it.
I think you can earn about 100,000 euros a year and then it's free. And after that you have to pay them something and buy a real license. It's the same for the Unreal Engine.
There is a certain amount of money you can make with your game or your assets or whatever, where the Unreal Engine is free. And after that they charge you some amount.
Usually the Unreal Engine charges you a certain fee per sale and Unreal you have to buy a professional license. That's the difference. Go.Dot is completely free. You can do whatever you want with Go.Dot.
This is an alpha version of the Unreal Engine we're using. Now it's 2019.3. So it may not be as stable as a normal Unity Engine, but we use that because it has some additional features.
And if you're downloading another older version of the Unity and I think in the labs here at the university, older versions of the Unity are installed. Some namings might be different.
For example, I will create a project with a universal render pipeline. Up to October this was called the lightweight render pipeline. But since designers confused lightweight with crap pipeline, everyone used the high definition render pipeline and on mobile high definition render pipeline.
That's way too excessive. The high definition render pipeline is a deferred pipeline in the Unity Engine. I don't know the curriculum of this lecture, but you probably heard about deferred rendering, did you?
Or didn't you? That's the thing where you render into buffers first and then you calculate lighting in a second pass. Well, that's the way to render if you have many, many lights.
If you don't know it, you can learn about it in interactive computer graphics. Another lecture from the chair.
The universal render pipeline is basically forward rendering. The thing you're learning from the beginning where you just you get your triangles and you shade your triangles and everything is OK.
I'll start this universal render pipeline project because well, I'm not sure if my notebook can handle the high definition pipeline.
So nothing else to set up. Unity will build a basic package for you and start up the editor. It'll take a while. They're working on this. They promise that it'll be faster in the future.
You can see it did open something. It's not there yet. I could have started it while talking. That would be the good approach.
So this is a sample project with a sample scene. Lots of the things you know from computer graphics like scene graphs or something like this. This is your scene graph. You're in a scene and there is a camera in the scene and there is a directional light.
Learn about that as well. I hope there's a post processing volume post processing like depth of field effects things to make your scene more beautiful afterwards after rendering.
And this is the example assets and you can see like we talked about the scene graphs. You can nest different assets with another with one another. And if I move the parent object, that's like the scene graph. Everything else is moving, moving along with this parent object.
The idea of a basic scene graph. There are some other things in here. As you can see, the colors are different here. That has special meaning. We'll start a new scene.
You can save that. A new empty scene. Then we can show you what's there. OK, this is your scene view. This down here, this is basically a view to a special folder on your hard drive. The assets folder. And it's just that. It's just a folder where you collect your assets and assets is everything from a texture to objects to mesh representations you want to render and your shader code and your scripting code you're writing for.
The engine. Everything is in the assets folder. You can organize this folder however you'd like. There are a few folder names that are reserved like resources is a special name for resources you want to load at runtime by name or something like this.
A material or something you need to load after the fact. And there is a plugin folder. This is you can write your native plugins in C++ or something to interface with other libraries like the Kinect or special hardware or something like that.
And the Unity gives you the ability to talk to those libraries in your scripting code so you can interface easily with other libraries you have on your machine. There is a special folder structure as well.
So a few names are reserved. You're not allowed to use them. But other than that you can organize your scenes however you'd like.
It's also you can if you need to add some resources or something you can drag and drop it into the Unity. You can copy it into the folder. Unity will see them and will load and process them.
It doesn't matter. As I said it's just it's just a folder with some conveniences.
There are I'm not loading any geometry or something like it. We're working with the primitives Unity is offering for our scene and you can easily add new 3D primitives by right clicking and create a sphere.
And as you can see it's a 3D editor you can you can move stuff around.
What you're what you're seeing down here the these these nice little points. This is something that is used for global illumination.
Those are basically something like light like light probes. They're taking light from each direction to process a very very simple form of global illumination for post processing screen space effects.
Basically we don't care about that at the moment. The important part is we have this this sphere here. Unity has two modes. We're in edit mode now.
If you press the play button we're starting into the game mode. This is the.
Yeah.
I probably can.
Better dark interfaces bright lights not not a good thing.
Presenters
Zugänglich über
Offener Zugang
Dauer
01:22:08 Min
Aufnahmedatum
2019-12-02
Hochgeladen am
2019-12-03 11:29:03
Sprache
de-DE